diff options
| author | Rafi Zadanly <rafizadanly@gmail.com> | 2022-11-19 13:55:00 +0700 |
|---|---|---|
| committer | Rafi Zadanly <rafizadanly@gmail.com> | 2022-11-19 13:55:00 +0700 |
| commit | 40bab7be1e0025c7c089e1eac17451ef155a989a (patch) | |
| tree | 5a87f4fd87f3c6bc0823e58614dd93ca6c97d2c8 /src/pages/shop/product/[slug].js | |
| parent | 679e565b4594bd172f2576926567a740760ff55e (diff) | |
Add page transition
Diffstat (limited to 'src/pages/shop/product/[slug].js')
| -rw-r--r-- | src/pages/shop/product/[slug].js | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/pages/shop/product/[slug].js b/src/pages/shop/product/[slug].js index a42e6cb9..923962e2 100644 --- a/src/pages/shop/product/[slug].js +++ b/src/pages/shop/product/[slug].js @@ -8,6 +8,7 @@ import currencyFormat from "../../../helpers/currencyFormat"; import { LazyLoadImage } from "react-lazy-load-image-component"; import "react-lazy-load-image-component/src/effects/blur.css"; import ProductSlider from "../../../components/product/ProductSlider"; +import Layout from "../../../components/Layout"; export async function getServerSideProps(context) { const { slug } = context.query; @@ -80,7 +81,7 @@ export default function ProductDetail({product}) { return ( <> <Header title={`${product.name} - Indoteknik`}/> - <main> + <Layout key={`/shop/product/${slug}`}> <LazyLoadImage effect="blur" src={product.image} alt={product.name} className="border-b border-gray-300 w-full h-[300px] object-contain object-center bg-white" /> <div className="p-4 pb-10"> @@ -170,7 +171,7 @@ export default function ProductDetail({product}) { </div> </div> - </main> + </Layout> </> ); }
\ No newline at end of file |
